import request from '@/utils/request';

export async function querySearch(params) {
  return request('/api/search/list', {
    params,
  });
}

export async function removeSearch(params) {
  return request('/api/search/list', {
    method: 'POST',
    data: { ...params, method: 'delete' },
  });
}

export async function addSearch(params) {
  return request('/api/search/list', {
    method: 'POST',
    data: { ...params, method: 'post' },
  });
}

export async function updateSearch(params) {
  return request('/api/search/list', {
    method: 'POST',
    requestType: 'form',
    data: { ...params, method: 'update' },
  });
}

//todo kim-stamp 请求api
